import request from "@/utils/request"

// 用户登录请求接口
export function login(data) {
    return request({
        url: "/api/admin/login",
        method: "post",
        data
    })
}

// 获取登录信息
export function getInfo(params = {}) {
    return request({
        url: "/api/admin/whoami",
        method: "get",
        params
    })
}

// 修改用户
export function setUser(data) {
    return request({
        url: "/api/admin",
        method: "PUT",
        data
    })
}
